<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" %>
<%@ include file="/admin/commons/taglib.jsp"%>
<%
    String path = request.getContextPath();
%>
<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>后台管理</title>
    <s:include value="/layouts/kindEditor.jsp"></s:include>
    <script type="text/javascript">
        $(function(){
            $("#user").addClass("active");
            $("#user").find("ul li").eq(1).addClass("active");
        })
    </script>
</head>
<body>
    <div class="admin">
        <div class="panel">
            <div class="panel-head"><strong>添加用户</strong></div>
            <div class="panel-body">
                <form action="user!save.action" id="form" method="post" enctype="multipart/form-data">
                    <input type="hidden" name="user.id" value="${user.id}"/>
                    <input type="hidden" name="user.thistime" value="${user.thistime}"/>
                    <input type="hidden" name="user.lasttime" value="${user.lasttime}"/>
                    <input type="hidden" name="user.num" value="${user.num}"/>
                    <input type="hidden" name="user.img" value="${user.img}"/>

                    <div class="form-group">
                        <div class="label"><label for="name">用户名</label></div>
                        <div class="field">
                            <input type="text" class="input" id="name" name="user.name" size="50" placeholder="请输入用户名"
                                   data-validate="required:请输入用户名" value="${user.name}"/>
                        </div>
                    </div>

                    <div class="form-group">
                        <div class="label"><label for="password">密码</label></div>
                        <div class="field">
                            <input type="password" class="input" id="password" value="${user.password}" name="user.password" size="50"/>
                        </div>
                    </div>

                    <div class="form-group">
                        <div class="label"><label >图片</label></div>
                        <div class="field">
                            <a class="button input-file" href="javascript:void(0);">+ 浏览文件<input size="100" type="file"
                                  name="file" data-validate="required:请选择上传文件,regexp#.+.(jpg|jpeg|png|gif)$:只能上传jpg|gif|png格式文件"/></a>
                        </div>
                    </div>

                    <div class="form-group">
                        <div class="label"><label >签名</label></div>
                        <div class="field">
                            <textarea id="kindEditor" name="user.qianming" class="input" rows="20" cols="50">
                                ${user.qianming}
                            </textarea>
                        </div>
                    </div>

                    <button class="button bg-blue" onclick="return checkForm()">提交</button>
                </form>
            </div>
        </div>
    </div>


</body>
</html>

